package com.weixing.mall.provider.model.dto;

import com.weixing.mall.provider.model.enums.WhetherEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;

/**
 * @ClassName CategoryPropDto
 * @Description TODO <br/>
 * @Author gjq
 * @Modified By:
 * @Date 2019/8/7
 * @Version 1.0
 **/
@Data
@ApiModel(description = "商品类目属性关联表")
public class CategoryPropDto {

    @ApiModelProperty(value = "id")
    private Long id;

    @ApiModelProperty(value = "商品类目id")
    @NotNull(message = "商品类目id不能为空")
    private Long categoryId;

    @ApiModelProperty(value = "属性名")
    @NotNull(message = "属性名不能为空")
    private String propName;

    @ApiModelProperty(value = "选项值（|分割）")
    @NotNull(message = "选项值（|分割）不能为空")
    private String optionArr;

    @ApiModelProperty(value = "是否必选")
    @NotNull(message = "是否必选不能为空")
    private WhetherEnum isRequired;

    @ApiModelProperty(value = "排序")
    private Double orderBy;
}
